<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    #grid {
      display: grid;
      grid-template-rows: repeat(5, 5em);
      grid-template-columns: repeat(10, 5em);
    }

    .one {
      grid-row-start: 2;
      grid-row-end: 4;
      grid-column-start: 2;
      grid-column-end: 4;
      background-color: aliceblue;
    }

    .two {
      grid-row-start: 1;
      grid-row-end: span 3;
      /* span number 相当于在 start 上增加或 end 上减少 number，这里表示 1 + 3 */
      grid-column-start: span 2;
      /* 这里表示 end - number，即 6 - 2 */
      grid-column-end: 6;
      background-color: antiquewhite;
    }

    .three {
      grid-row-start: 4;
      /* 不指定 end，默认占据一个栅格单元 */
      grid-column-start: 3;
      background-color: aqua;
    }
    
    .four {
      grid-row-start: -2;
      grid-column-start: -2;
      background-color: aquamarine;
    }
  </style>
</head>

<body>
  <div id="grid">
    <div class="one">a</div>
    <div class="two">b</div>
    <div class="three">c</div>
    <div class="four">d</div>
  </div>
</body>

</html>